3.1.46 \(\int \frac {a+b \log (\frac {\sqrt {1-c x}}{\sqrt {1+c x}})}{1-c^2 x^2} \, dx\) [46]

Optimal. Leaf size=37 \[ -\frac {\left (a+b \log \left (\frac {\sqrt {1-c x}}{\sqrt {1+c x}}\right )\right )^2}{2 b c} \]

[Out]

-1/2*(a+b*ln((-c*x+1)^(1/2)/(c*x+1)^(1/2)))^2/b/c

________________________________________________________________________________________

Rubi [A]
time = 0.05, antiderivative size = 37, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 38, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.105, Rules used = {2573, 2576, 12, 2338} \begin {gather*} -\frac {\left (a+b \log \left (\frac {\sqrt {1-c x}}{\sqrt {c x+1}}\right )\right )^2}{2 b c} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(a + b*Log[Sqrt[1 - c*x]/Sqrt[1 + c*x]])/(1 - c^2*x^2),x]

[Out]

-1/2*(a + b*Log[Sqrt[1 - c*x]/Sqrt[1 + c*x]])^2/(b*c)

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 2338

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))/(x_), x_Symbol] :> Simp[(a + b*Log[c*x^n])^2/(2*b*n), x] /; FreeQ[{a
, b, c, n}, x]

Rule 2573

Int[((A_.) + Log[(e_.)*(u_)^(n_.)*(v_)^(mn_)]*(B_.))^(p_.)*(w_.), x_Symbol] :> Subst[Int[w*(A + B*Log[e*(u/v)^
n])^p, x], e*(u/v)^n, e*(u^n/v^n)] /; FreeQ[{e, A, B, n, p}, x] && EqQ[n + mn, 0] && LinearQ[{u, v}, x] &&  !I
ntegerQ[n]

Rule 2576

Int[((A_.) + Log[(e_.)*(((a_.) + (b_.)*(x_))/((c_.) + (d_.)*(x_)))^(n_.)]*(B_.))^(p_.)*(P2x_)^(m_.), x_Symbol]
 :> With[{f = Coeff[P2x, x, 0], g = Coeff[P2x, x, 1], h = Coeff[P2x, x, 2]}, Dist[b*c - a*d, Subst[Int[(b^2*f
- a*b*g + a^2*h - (2*b*d*f - b*c*g - a*d*g + 2*a*c*h)*x + (d^2*f - c*d*g + c^2*h)*x^2)^m*((A + B*Log[e*x^n])^p
/(b - d*x)^(2*(m + 1))), x], x, (a + b*x)/(c + d*x)], x]] /; FreeQ[{a, b, c, d, e, A, B, n}, x] && PolyQ[P2x,
x, 2] && NeQ[b*c - a*d, 0] && IntegerQ[m] && IGtQ[p, 0]

Rubi steps

\begin {align*} \int \frac {a+b \log \left (\frac {\sqrt {1-c x}}{\sqrt {1+c x}}\right )}{1-c^2 x^2} \, dx &=-\frac {\text {Subst}\left (\int \frac {a+b \log (x)}{x} \, dx,x,\frac {\sqrt {1-c x}}{\sqrt {1+c x}}\right )}{c}\\ &=-\frac {\left (a+b \log \left (\frac {\sqrt {1-c x}}{\sqrt {1+c x}}\right )\right )^2}{2 b c}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.01, size = 37, normalized size = 1.00 \begin {gather*} -\frac {\left (a+b \log \left (\frac {\sqrt {1-c x}}{\sqrt {1+c x}}\right )\right )^2}{2 b c} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(a + b*Log[Sqrt[1 - c*x]/Sqrt[1 + c*x]])/(1 - c^2*x^2),x]

[Out]

-1/2*(a + b*Log[Sqrt[1 - c*x]/Sqrt[1 + c*x]])^2/(b*c)

________________________________________________________________________________________

Maple [F]
time = 0.11, size = 0, normalized size = 0.00 \[\int \frac {a +b \ln \left (\frac {\sqrt {-c x +1}}{\sqrt {c x +1}}\right )}{-c^{2} x^{2}+1}\, dx\]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+b*ln((-c*x+1)^(1/2)/(c*x+1)^(1/2)))/(-c^2*x^2+1),x)

[Out]

int((a+b*ln((-c*x+1)^(1/2)/(c*x+1)^(1/2)))/(-c^2*x^2+1),x)

________________________________________________________________________________________

Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 105 vs. \(2 (31) = 62\).
time = 0.29, size = 105, normalized size = 2.84 \begin {gather*} \frac {1}{2} \, b {\left (\frac {\log \left (c x + 1\right )}{c} - \frac {\log \left (c x - 1\right )}{c}\right )} \log \left (\frac {\sqrt {-c x + 1}}{\sqrt {c x + 1}}\right ) + \frac {1}{2} \, a {\left (\frac {\log \left (c x + 1\right )}{c} - \frac {\log \left (c x - 1\right )}{c}\right )} + \frac {{\left (\log \left (c x + 1\right )^{2} - 2 \, \log \left (c x + 1\right ) \log \left (c x - 1\right ) + \log \left (c x - 1\right )^{2}\right )} b}{8 \, c} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log((-c*x+1)^(1/2)/(c*x+1)^(1/2)))/(-c^2*x^2+1),x, algorithm="maxima")

[Out]

1/2*b*(log(c*x + 1)/c - log(c*x - 1)/c)*log(sqrt(-c*x + 1)/sqrt(c*x + 1)) + 1/2*a*(log(c*x + 1)/c - log(c*x -
1)/c) + 1/8*(log(c*x + 1)^2 - 2*log(c*x + 1)*log(c*x - 1) + log(c*x - 1)^2)*b/c

________________________________________________________________________________________

Fricas [A]
time = 0.35, size = 47, normalized size = 1.27 \begin {gather*} -\frac {b \log \left (\frac {\sqrt {-c x + 1}}{\sqrt {c x + 1}}\right )^{2} + 2 \, a \log \left (\frac {\sqrt {-c x + 1}}{\sqrt {c x + 1}}\right )}{2 \, c} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log((-c*x+1)^(1/2)/(c*x+1)^(1/2)))/(-c^2*x^2+1),x, algorithm="fricas")

[Out]

-1/2*(b*log(sqrt(-c*x + 1)/sqrt(c*x + 1))^2 + 2*a*log(sqrt(-c*x + 1)/sqrt(c*x + 1)))/c

________________________________________________________________________________________

Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 61 vs. \(2 (29) = 58\).
time = 4.59, size = 61, normalized size = 1.65 \begin {gather*} \begin {cases} - \frac {a \operatorname {atan}{\left (\frac {x}{\sqrt {- \frac {1}{c^{2}}}} \right )}}{c^{2} \sqrt {- \frac {1}{c^{2}}}} & \text {for}\: b = 0 \\a x & \text {for}\: c = 0 \\- \frac {\left (a + b \log {\left (\frac {\sqrt {- c x + 1}}{\sqrt {c x + 1}} \right )}\right )^{2}}{2 b c} & \text {otherwise} \end {cases} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*ln((-c*x+1)**(1/2)/(c*x+1)**(1/2)))/(-c**2*x**2+1),x)

[Out]

Piecewise((-a*atan(x/sqrt(-1/c**2))/(c**2*sqrt(-1/c**2)), Eq(b, 0)), (a*x, Eq(c, 0)), (-(a + b*log(sqrt(-c*x +
 1)/sqrt(c*x + 1)))**2/(2*b*c), True))

________________________________________________________________________________________

Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 86 vs. \(2 (31) = 62\).
time = 5.02, size = 86, normalized size = 2.32 \begin {gather*} -\frac {b \log \left (c x + 1\right )^{2}}{8 \, c} + \frac {b \log \left (c x - 1\right )^{2}}{8 \, c} + \frac {1}{4} \, {\left (\frac {b \log \left (c x + 1\right )}{c} - \frac {b \log \left (c x - 1\right )}{c}\right )} \log \left (-c x + 1\right ) + \frac {a \log \left (c x + 1\right )}{2 \, c} - \frac {a \log \left (c x - 1\right )}{2 \, c} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log((-c*x+1)^(1/2)/(c*x+1)^(1/2)))/(-c^2*x^2+1),x, algorithm="giac")

[Out]

-1/8*b*log(c*x + 1)^2/c + 1/8*b*log(c*x - 1)^2/c + 1/4*(b*log(c*x + 1)/c - b*log(c*x - 1)/c)*log(-c*x + 1) + 1
/2*a*log(c*x + 1)/c - 1/2*a*log(c*x - 1)/c

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.03 \begin {gather*} \int -\frac {a+b\,\ln \left (\frac {\sqrt {1-c\,x}}{\sqrt {c\,x+1}}\right )}{c^2\,x^2-1} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-(a + b*log((1 - c*x)^(1/2)/(c*x + 1)^(1/2)))/(c^2*x^2 - 1),x)

[Out]

int(-(a + b*log((1 - c*x)^(1/2)/(c*x + 1)^(1/2)))/(c^2*x^2 - 1), x)

________________________________________________________________________________________